package sicnu.cs.aps.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import sicnu.cs.aps.domain.entity.ActivityRestriction;

import java.lang.reflect.Array;
import java.util.ArrayList;
import java.util.List;

/**
 * @author lucker
 * @date 2022/5/30 18:04
 */
@Mapper
public interface ActivityRestrictionMapper extends BaseMapper<ActivityRestriction> {
    /**
     * 插入活动的学院限制到t_activity_college_restriction表
     *
     * @param activityId
     * @param collegeIdList
     */
    void insertActivityCollegeRestriction(@Param("activityId") Long activityId, @Param("collegeIdList") List<Long> collegeIdList);


    /**
     * 查询符合学院要求的活动
     *
     * @param collegeId 学院id
     * @return 活动id列表
     */
    List<Long> selectEligibleActivityIdByCollegeId(Long collegeId);

}
